<template>
  <div class="xq">
    <p>{{ names }}</p>

    <div class="ul">
      <p>{{ xiangqing.id }}</p>
      <el-divider></el-divider>
      <p><span>设备名称:</span>{{ xiangqing.name }}</p>
      <p><span>设备状态:</span>{{ xiangqing.status }}</p>
      <p><span>设备分类:</span>{{ xiangqing.category }}</p>
      <p><span>数量:</span>{{ xiangqing.number }}</p>
      <p><span>单价:</span>{{ xiangqing.price }}</p>
      <p><span>购置日期:</span>{{ xiangqing.time }}</p>
      <el-button @click="handleClick" size="medium" type="success"
        >返回列表</el-button
      >
    </div>
  </div>
</template>

<script>
export default {
  name: "XiangQing",
  props: ["xiangqing", "names"],
  mounted() {
    console.log(this.xiangqing, this.names);
  },
  methods: {
    handleClick() {
      this.$bus.$emit("fhlb");
    },
  },
};
</script>

<style lang="less" scoped>
p {
  font-size: 20px;
}
.xq {
  width: 100%;
  height: 100%;
  // background: rgb(100, 97, 97);
  padding: 30px;
}
span {
  width: 100px;
  height: 30px;
  display: inline-block;
  text-align: right;
  margin: 10px 20px;
}
.ul {
  width: 90%;
  padding: 30px 20px;
  background: rgb(165, 169, 173);
  border-radius: 20px;
  li {
    margin-top: 20px;
  }
  button {
    margin: 50px;
  }
}
</style>